package com.bauer.module.common.error;

import java.io.Serializable;

/**
 * @program: clock
 * @description:
 * @author: bauer weo
 * @create: 2019-08-29 21:20
 */
public class ClockException extends RuntimeException implements Serializable {

    private String errorCode;

    private String errorMsg;

    public ClockException() {
    }

    public ClockException(ErrorCode errorCode) {
        super(errorCode.getCode() + errorCode.getMessage());
        this.errorCode = errorCode.getCode();
        this.errorMsg = errorCode.getMessage();

    }

    public ClockException(String errorCode, String errorMsg) {
        super(errorCode + errorMsg);
        this.errorCode = errorCode;
        this.errorMsg = errorMsg;
    }

    public String getErrorCode() {
        return errorCode;
    }

    public void setErrorCode(String errorCode) {
        this.errorCode = errorCode;
    }

    public String getErrorMsg() {
        return errorMsg;
    }

    public void setErrorMsg(String errorMsg) {
        this.errorMsg = errorMsg;
    }
}
